package day10.Exer;

public class Keyboard implements Usb {
    private String brand;
    private String type;

    public Keyboard(String brand, String type) {
        this.brand = brand;
        this.type = type;
    }

    public String getBrand() {
        return brand;
    }

    public void setBrand(String brand) {
        this.brand = brand;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    @Override
    public void plugin() {
        System.out.println("键盘被插上了");
    }

    @Override
    public void work() {
        System.out.println("键盘可以使用了");
    }

    @Override
    public void unuplug() {
        System.out.println("键盘被拔掉了");
    }
    public String toString() {
        return "这是一个"+brand+"键盘";
    }
}
